<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>我的生活</title>
    <meta name="viewport" content="initial-scale=1, maximum-scale=1">
    <link rel="shortcut icon" href="/favicon.ico">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">

    <link rel="stylesheet" href="http://g.alicdn.com/msui/sm/0.6.2/css/sm.min.css">
    <link rel="stylesheet" href="http://g.alicdn.com/msui/sm/0.6.2/css/sm-extend.min.css">

  </head>
  <body>
<header class="bar bar-nav">
  <h1 class="title">视图列表</h1>
</header>
<div id="J_serverList" class="content">
  <div v-for="item in couponList" class="list-block">
    <ul>
      <li class="item-content">
        <div class="item-media"><i class="icon icon-f7"></i></div>
        <div class="item-inner">
          <div class="item-title">优惠券</div>
          <div class="item-after">{{item.name}}</div>
        </div>
      </li>
      <li class="item-content">
        <div class="item-media"><i class="icon icon-f7"></i></div>
        <div class="item-inner">
          <div class="item-title">金额</div>
          <div class="item-after">{{item.amount}}</div>
        </div>
      </li>
    </ul>
  </div>

</div>

    <script type='text/javascript' src='http://g.alicdn.com/sj/lib/zepto/zepto.min.js' charset='utf-8'></script>
    <script type='text/javascript' src='http://g.alicdn.com/msui/sm/0.6.2/js/sm.min.js' charset='utf-8'></script>
    <script type='text/javascript' src='http://g.alicdn.com/msui/sm/0.6.2/js/sm-extend.min.js' charset='utf-8'></script>
    <script type='text/javascript' src='js/utils.js'></script>
    <script type='text/javascript' src='js/vue.js'></script>
    <script>
    $(function () {
        AjaxIO.getJSON("/coupon/list", {}, function (result) {
            console.log(result.data);
            if(result.status){
                new Vue ({
                    el: '#J_serverList',
                    data: result.data
                })
            }
        });
    })
</script>
  </body>
</html>